import React from 'react'
import { LaptopOutlined } from '@ant-design/icons'
import { Role } from 'Model/role'

export type MenuList = {
  title: string
  url: string
  Icon: typeof LaptopOutlined
  permission: Role[]
  children?: MenuList[]
}

export const routes: MenuList[] = [
  {
    title: '主菜单1',
    Icon: LaptopOutlined,
    url: '/home/report',
    permission: [Role.admin, Role.storageAdmin],
    children: [
      {
        title: '子菜单1',
        Icon: LaptopOutlined,
        url: '/home/report/inventory',
        permission: [Role.admin, Role.storageAdmin],
      },
      {
        title: '子菜单2',
        Icon: LaptopOutlined,
        url: '/home/report/warning',
        permission: [Role.admin, Role.storageAdmin],
      },
    ],
  },
  {
    title: '主菜单2',
    Icon: LaptopOutlined,
    url: '/home/xx',
    permission: [Role.admin, Role.storageAdmin],
    children: [
      {
        title: '子菜单1',
        Icon: LaptopOutlined,
        url: '/home/report/xxx',
        permission: [Role.admin, Role.storageAdmin],
      },
      {
        title: '子菜单2',
        Icon: LaptopOutlined,
        url: '/home/report/xxxx',
        permission: [Role.admin, Role.storageAdmin],
      },
    ],
  },
]
